﻿using OnHook.Business.Model;
using OnHook.Business.Vo.UserInfo;
using OnHook.Domain.Enums;

namespace OnHook.Business.IServices.Auth
{
    public interface IAuthService
    {

        /// <summary>
        /// 获取授权地址
        /// </summary>
        /// <param name="platform"></param>
        /// <param name="authCallBackUrl"></param>
        /// <param name="returnUrl"></param>
        /// <param name="invitecode"></param>
        /// <returns></returns>
        Task<string> GetAuthUrlAsync(EnumPlatform platform, string authCallBackUrl, string returnUrl, string invitecode);

        /// <summary>
        /// 获取授权后跳转地址
        /// </summary>
        /// <param name="code">授权回传的code</param>
        /// <param name="state">参数，关联缓存</param>
        /// <returns></returns>
        Task<string> GetAuthCallBackUrlAsync(string code, string state);

        /// <summary>
        /// 开房平台获取用户信息登录
        /// </summary>
        /// <param name="model"></param>
        /// <returns></returns>
        Task<LoginUserVo> OpenLoginAsync(OpenUserInfoModel model);
        /// <summary>
        /// 模拟登录
        /// </summary>
        /// <returns></returns>
        Task<LoginUserVo> TestLogin();
    }
}
